<!DOCTYPE html>
<html lang="en" xmlns:th="http://www.thymeleaf.org">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>OA模拟与实现</title>
    <link rel="stylesheet" th:href="@{/bootstrap/bootstrap-3.3.7-dist/css/bootstrap.min.css}"/>
    <script th:src="@{/js/jquery-3.2.1.min.js}"></script>
    <style>
      .tb{
          margin-top: 10px;
      }
    </style>
</head>
<body>
    <div class="container-fluid">
        <ol class="breadcrumb nav-top">
            <li><a th:href="@{~/router/index.html}" target="main">首页</a></li>
            <li class="active">院部管理</li>
        </ol>
        <form class="form-inline">
            <!--<div class="form-group">-->
              <!--<label for="teaName">院名称：</label>-->
              <!--<input type="text" class="form-control" id="teaName" placeholder="请输入院名称">-->
            <!--</div>-->
            <!--<button type="submit" class="btn btn-primary">查询</button>-->
            <!--<b>|</b>-->
            <!--<a href="addDepart.html" target="main" type="button" class="btn btn-primary">添加</a>-->
        </form>
        <table class="table table-striped tb">
            <thead>
                <tr class="text-center">
                    <td>编&nbsp;号</td>
                    <td>专&nbsp;业</td>
                    <td>院&nbsp;部</td>
                    <td>人&nbsp;数</td>
                    <td>负责人</td>
                    <td>操&nbsp;作</td>
                </tr>
            </thead>
            <tbody>
                <tr class="text-center" th:object="${depart}" th:each="depart : ${departList}">
                    <td th:text="*{id}">#001</td>
                    <td th:text="*{major}">计算机科学与技术</td>
                    <td th:text="*{domain.domainname}">信息工程学院</td>
                    <td th:text="*{num}">500</td>
                    <td th:text="*{principle}">tt</td>
                    <td>
                        <!--<a th:href="@{/depart/delete/{id}(id=*{id})}">删除</a>&nbsp;|&nbsp;-->
                        <a th:href="@{/depart/toEdit(id=*{id})}">修改</a>
                    </td>
                </tr>
            </tbody>
            
        </table>
        <div class="text-center">
            <nav aria-label="Page navigation">
                <ul class="pagination">
                  <li>
                    <a th:href="@{/depart/depart.html(currentPage=${pageUtil.currentPage==1?1:pageUtil.currentPage-1})}" aria-label="Previous">
                      <span aria-hidden="true">&laquo;</span>
                    </a>
                  </li>
                  <li th:each="num : ${#numbers.sequence(1,pageUtil.totalPage)}"><a th:href="@{/depart/depart.html(currentPage=${num})}" th:text="${num}">1</a></li>

                  <li>
                    <a th:href="@{/depart/depart.html(currentPage=${pageUtil.currentPage==pageUtil.totalPage?pageUtil.totalPage:pageUtil.currentPage+1})}" aria-label="Next">
                      <span aria-hidden="true">&raquo;</span>
                    </a>
                  </li>
                </ul>
              </nav>
        </div>
    </div>
</body>
</html>